angular.module('sale.router', [])
.config(function($stateProvider) {
  $stateProvider

//销售Tab
  .state('app.sale', {
    url: 'sale',
    views: {
      'menuContent': {
        templateUrl: 'templates/ceo/tab-sale.html',
        controller: 'SaleCtrl'
      }
    }
  })
    //品牌统计
    .state('app.brand-sale', {
      url: 'brand-sale',
      views: {
        'menuContent': {
          templateUrl: 'templates/sale/brand-analytics.html',
          controller: 'BrandSaleCtrl'
        }
      }
    })
      //品牌销售详情统计
      .state('app.brand-sale-detail', {
        url: 'brand-sale-detail-:brandName',
        views: {
          'menuContent': {
            templateUrl: 'templates/sale/brand-detail.html',
            controller: 'BrandSaleDetailCtrl'
          }
        }
      })
    //机型统计
    .state('app.type-sale', {
      url: 'type-sale',
      views: {
        'menuContent': {
          templateUrl: 'templates/sale/type-analytics.html',
          controller: 'TypeSaleCtrl'
        }
      }
    })
    //店铺统计
    .state('app.store-sale', {
      url: 'store-sale',
      views: {
        'menuContent': {
          templateUrl: 'templates/sale/store-analytics.html',
          controller: 'StoreSaleCtrl'
        }
      }
    })
    //销售员统计
    .state('app.seller-sale', {
      url: 'seller-sale',
      views: {
        'menuContent': {
          templateUrl: 'templates/sale/seller-analytics.html',
          controller: 'SellerSaleCtrl'
        }
      }
    });
});